Add swap-in wallet and splice-in via Electrum backend#1
Add swap-in wallet and splice-in via Electrum backend#1matthiasdebernardini wants to merge 1 commit intomasterfrom
Conversation
…kend Port swap-in functionality from PR ACINQ#69 to current master by switching the blockchain backend from MempoolSpaceClient to ElectrumClient. This enables peer.swapInWallet (which requires IElectrumClient) and adds three new API endpoints: getswapinaddress, swapinwalletbalance, and splicein. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Mainnet E2E Test ReportSetup
What Worked
Deposits Made (mainnet, real sats)
Timeline
Issue: Channel Opening FailureRoot cause: Electrum server returned very low feerate estimates: This resulted in The channel was ultimately opened by importing the seed into the Phoenix mobile app (which uses its own feerate estimation), not by phoenixd's auto channel creation. Phoenixd then synced the channel state from the peer and successfully performed a splice-out. This is NOT a version mismatch issue — same failure occurred with both Recommendations
Final Balances
ConclusionThe swap-in wallet infrastructure (address generation, UTXO detection, balance tracking, auto channel request) works correctly end-to-end on mainnet. The splice-out via |
Summary
MempoolSpaceClienttoElectrumClient, enablingpeer.swapInWallet(gated behindIElectrumClient)--electrum-serverCLI option with per-chain defaults (ACINQ's Electrum servers), deprecates--mempool-space-urlGET /getswapinaddress,GET /swapinwalletbalance,POST /splicein(full-access)getswapinaddress,swapinwalletbalance,spliceintests/test_swap_in_e2e.sh)Ports the core functionality from ACINQ/phoenixd#69 to current master, following the same pattern Phoenix mobile uses.
Status
./phoenixd --chain testnetand verify Electrum + peer connectionsphoenix-cli getswapinaddressreturns valid testnet addressTest plan
tests/test_swap_in_e2e.shthrough the full swap-in → splice-in → splice-out cycle🤖 Generated with Claude Code